/* 
 * File:   FileThread.cpp
 * Author: Imre Tabur
 * 
 */
#include "FileThread.h"

using namespace CloudyStorage;

FileThread::FileThread() : file(0), workerThread(0) {
}

FileThread::~FileThread() {
    delete file;
    delete workerThread;
}

void FileThread::worker(const FileThread& fileThread) {
    fileThread.run();
}

void FileThread::start() {
    this->workerThread = new boost::thread(FileThread::worker, *this);
}

void FileThread::stop() {
    
}

void FileThread::run() const {

}

void FileThread::join() {
    this->workerThread->join();
    delete this->workerThread;
    this->workerThread = 0;
}

File *FileThread::getFile() {
    return this->file;
}

void FileThread::setFile(File *file) {
    this->file = file;
}

void FileThread::push() {
}

void FileThread::pull() {
}
